Formalizing a Broader Recursion Coverage in SQL

نویسندگان

  • Gabriel Aranda-López
  • Susana Nieva
  • Fernando Sáenz-Pérez
  • Jaime Sánchez-Hernández
چکیده

SQL is the de facto standard language for relational databases and has evolved by introducing new resources and expressive capabilities, such as recursive definitions in queries and views. Recursion was included in the SQL-99 standard, but this approach is limited as only linear recursion is allowed, mutual recursion is not supported, and negation cannot be combined with recursion. In this work, we propose a new approach, called R-SQL, aimed to overcome these limitations and others, allowing in particular cycles in recursive definitions of graphs and mutually recursive relation definitions. In order to combine recursion and negation, we import ideas from the deductive database field, such as stratified negation, based on the definition of a dependency graph between relations involved in the database. We develop a formal framework using a stratified fixpoint semantics and introduce a proof-of-concept implementation.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Incorporating Hypothetical Views and Extended Recursion into SQL Database Systems

Current database systems supporting recursive SQL impose restrictions on queries such as linearity, and do not implement mutual recursion. In a previous work we presented the language and prototype R-SQL to overcome those drawbacks. Now we introduce a formalization and an implementation of the database system HR-SQL that, in addition to extended recursion, incorporates hypothetical reasoning in...

متن کامل

Data Retrieval and Aggregates in SQL*/NR

Standard SQL is incapable of handling recursive database queries and nested relations. A proposed solution to allow recursion in SQL was given in SQL KC93], while a solution to allow nested relations in SQL was given in SQL=NF RKB87]. However, these two problems with SQL were handled separately, and an extended SQL that handles both recursive queries and nested relations is still lacking. To ov...

متن کامل

Operational Semantics of an Imperative Language in Definite Clauses

We present the “big-step” operational semantics of a small programming language NIL (Natural Imperative Language) in definite clauses, thus building on the fixpoint semantics of logic programs. NIL operates on a state which is just a sequence of counters. As basic statements NIL has incrementation, decrementation and test for null. NIL allows for sequential composition and non-deterministic cho...

متن کامل

Formalizing and Refining Authorization in SQL

The SQL standard specifies authorization via a large set of rather opaque rules, which are difficult to understand and dangerous to change. To make the model easier to work with, we formalize the implicit principles behind SQL authorization. We then discuss two extensions, for explicit metadata privileges and general privilege inference on derived objects. Although these are quite simple and ea...

متن کامل

An Ordinal Analysis of Admissible Set Theory Using Recursion on Ordinal Notations

The notion of a function from N to N defined by recursion on ordinal notations is fundamental in proof theory. Here this notion is generalized to functions on the universe of sets, using notations for well-orderings longer than the class of ordinals. The generalization is used to bound the rate of growth of any function on the universe of sets that is Σ1-definable in Kripke-Platek admissible se...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013